/*********************\
* Author:Dzlua
* QQ:505544956
* Time:2017/04/16
\**********************/
#ifndef __LUA_TREENODE_H__
#define __LUA_TREENODE_H__
#pragma once

#include "../List/LuaListContainerElement.h"

namespace DuiLib {

class LuaTreeNode : public LuaListContainerElement
{
    SDLUA_CLASS_DECLARE(LuaTreeNode);

    void Invalidate();
    bool Select(bool bSelect );
    bool SelectMulti(bool bSelect);

    int Add(LuaState *L);
    int AddAt(LuaState *L);
    int Remove(LuaState *L);

    void SetVisibleTag(bool _IsVisible);
    bool GetVisibleTag();
    int SetItemText(LuaState *L);
    int GetItemText(LuaState *L);
    void CheckBoxSelected(bool _Selected);
    bool IsCheckBoxSelected();
    bool IsHasChild();
    long GetTreeLevel();
    int AddChildNode(LuaState *L);
    int RemoveAt(LuaState *L);
    int SetParentNode(LuaState *L);
    int GetParentNode(LuaState *L);
    long GetCountChild();
    int SetTreeView(LuaState *L);
    int GetTreeView(LuaState *L);
    int GetChildNode(LuaState *L);
    void SetVisibleFolderBtn(bool _IsVisibled);
    bool GetVisibleFolderBtn();
    void SetVisibleCheckBtn(bool _IsVisibled);
    bool GetVisibleCheckBtn();
    void SetItemTextColor(DWORD _dwItemTextColor);
    DWORD GetItemTextColor();
    void SetItemHotTextColor(DWORD _dwItemHotTextColor);
    DWORD GetItemHotTextColor();
    void SetSelItemTextColor(DWORD _dwSelItemTextColor);
    DWORD GetSelItemTextColor();
    void SetSelItemHotTextColor(DWORD _dwSelHotItemTextColor);
    DWORD GetSelItemHotTextColor();

    //CStdPtrArray GetTreeNodes();
    int			 GetTreeIndex();
    int			 GetNodeIndex();
};

}

#endif //__LUA_TREENODE_H__